package com.example.demo.controller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.example.demo.domain.Tag;
import com.example.demo.service.TagService;

@Controller
public class TagController {
	@Autowired
	TagService tagService;
	
	@RequestMapping("/tag")
	@ResponseBody
	public List<Tag> getTags() {
		return tagService.getTagsOfArticleByAid((long) 1);
	}
}
